package com.ruoyi.project.common.appnotice.domain;

import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.Date;
import java.util.List;

/**
 * 系统弹窗对象 notice
 *
 * @author shixiangwen
 * @date 2022-03-18
 */
public class AppNotice extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 通知ID
     */
    private Long id;

    /**
     * 图片
     */
    @Excel(name = "图片")
    private String img;

    /**
     * 内容
     */
    @Excel(name = "内容")
    private String content;

    /**
     * 跳转类型
     */
    @Excel(name = "跳转类型")
    private Integer targetType;

    /**
     * 跳转URL
     */
    @Excel(name = "跳转URL")
    private String targetUrl;

    /**
     * 弹窗天数
     */
    @Excel(name = "弹窗天数")
    private Long promptCount;

    /**
     * 弹窗间隔天数
     */
    @Excel(name = "弹窗间隔天数")
    private Long promptIntervalDay;

    /**
     * 创建时间
     */
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createdTime;

    /**
     * 开始时间
     */
    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date startTime;

    /**
     * 结束时间
     */
    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endTime;

    /**
     * 状态
     */
    @Excel(name = "状态")
    private Integer status;

    /**
     * 渠道列表
     */
    @Excel(name = "渠道列表")
    private String channel;

    /**
     * 是否灰度
     */
    @Excel(name = "是否灰度")
    private Integer grey;

    /**
     * 灰度的桶
     */
    @Excel(name = "灰度的桶")
    private String greyIdx;

    private List<Integer> greyIdxs;

    private List<String> channels;

    /**
     * 是否打开渠道
     */
    @Excel(name = "是否打开渠道")
    private Integer channelOpen;

    /**
     * 应用
     */
    @Excel(name = "应用")
    private String app;

    /**
     * 版本
     */
    @Excel(name = "版本")
    private String version;

    private String maxVersion;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setImg(String img) {
        this.img = img;
    }

    public String getImg() {
        return img;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getContent() {
        return content;
    }

    public void setTargetType(Integer targetType) {
        this.targetType = targetType;
    }

    public Integer getTargetType() {
        return targetType;
    }

    public void setTargetUrl(String targetUrl) {
        this.targetUrl = targetUrl;
    }

    public String getTargetUrl() {
        return targetUrl;
    }

    public void setPromptCount(Long promptCount) {
        this.promptCount = promptCount;
    }

    public Long getPromptCount() {
        return promptCount;
    }

    public void setPromptIntervalDay(Long promptIntervalDay) {
        this.promptIntervalDay = promptIntervalDay;
    }

    public Long getPromptIntervalDay() {
        return promptIntervalDay;
    }

    public void setCreatedTime(Date createdTime) {
        this.createdTime = createdTime;
    }

    public Date getCreatedTime() {
        return createdTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public Date getStartTime() {
        return startTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public Date getEndTime() {
        return endTime;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getStatus() {
        return status;
    }

    public void setChannel(String channel) {
        this.channel = channel;
    }

    public String getChannel() {
        return channel;
    }

    public void setGrey(Integer grey) {
        this.grey = grey;
    }

    public Integer getGrey() {
        return grey;
    }

    public void setGreyIdx(String greyIdx) {
        this.greyIdx = greyIdx;
    }

    public String getGreyIdx() {
        return greyIdx;
    }

    public void setChannelOpen(Integer channelOpen) {
        this.channelOpen = channelOpen;
    }

    public Integer getChannelOpen() {
        return channelOpen;
    }

    public void setApp(String app) {
        this.app = app;
    }

    public String getApp() {
        return app;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public String getVersion() {
        return version;
    }

    public List<Integer> getGreyIdxs() {
        return greyIdxs;
    }

    public void setGreyIdxs(List<Integer> greyIdxs) {
        this.greyIdxs = greyIdxs;
    }

    public List<String> getChannels() {
        return channels;
    }

    public void setChannels(List<String> channels) {
        this.channels = channels;
    }

    public String getMaxVersion() {
        return maxVersion;
    }

    public void setMaxVersion(String maxVersion) {
        this.maxVersion = maxVersion;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("img", getImg())
                .append("content", getContent())
                .append("targetType", getTargetType())
                .append("targetUrl", getTargetUrl())
                .append("promptCount", getPromptCount())
                .append("promptIntervalDay", getPromptIntervalDay())
                .append("createdTime", getCreatedTime())
                .append("startTime", getStartTime())
                .append("endTime", getEndTime())
                .append("status", getStatus())
                .append("channel", getChannel())
                .append("grey", getGrey())
                .append("greyIdx", getGreyIdx())
                .append("channelOpen", getChannelOpen())
                .append("app", getApp())
                .append("version", getVersion())
                .toString();
    }
}
